<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

$user_id = get_loggedin_userid();

$device_token = get_input('device_token');
$pro = get_input('pro');
$env = get_input('env');

if(dt_set_device_token_for_user_id($user_id, $device_token, $pro, $env)) {
    echo json_encode(export_result(200, "1"));
} else {
    echo json_encode(export_result(400, "0"));
}

?>
